<%= div_for link do %>
  <% if link.image %>
    <div class="thumbnail">
      <%= image_tag(link.image)%>
      <%= hidden_field_tag "link[image]", link.image %>
    </div>
  <% end %>
  <div class="info">
    <div class="title">
      <%= text_field_tag "link[title]", link.title %>
    </div>

    <div class="description">
      <%= text_area_tag "link[description]", link.description %>
    </div>

    <% if link.callback_url %>
        <%= hidden_field_tag "link[callback_url]", link.callback_url %>
    <% end %>
    <% if link.width %>
        <%= hidden_field_tag "link[width]", link.width %>
    <% end %>
    <% if link.height %>
        <%= hidden_field_tag "link[height]", link.height %>
    <% end %>
  </div>
<% end %>
